import { Logger } from "./Logger";

const fs = require("fs")
const path = require("path")

export class FileUtil {

    public static instance: FileUtil = new FileUtil();


    public write_json(jsonStr: string, filePath: string) {
        if (fs.existsSync(filePath)) {
            fs.writeFileSync(filePath, jsonStr);
        } else {
            Logger.warn("文件不存在=", filePath)
        }
    }

}